import QtQuick 2.5
import QtQuick.Controls 2.1
import ".."

Rectangle
{
    id: myBigButton
    height: 100
    width: 238
    radius: 20
    clip: true
    property alias name: title.text
    property alias source: icon.source
    property alias size: title.font.pixelSize
    signal clicked()
    scale: clickArea.pressed ? 0.95 : 1
    Image
    {
        id: icon
        anchors.left: parent.left
        anchors.leftMargin: 20
        anchors.verticalCenter: parent.verticalCenter
    }
    Text
    {
        id: title
        anchors.left: icon.right
        anchors.leftMargin: 20
        anchors.verticalCenter: parent.verticalCenter
        font.family: Common.fontMain
        font.pixelSize: 16
        color: Common.colorTextBlack
    }
    MouseArea
    {
        id: clickArea
        anchors.fill: parent
        onClicked:
        {
            console.log(name)
            GET_UAC.playBeep()
            myBigButton.clicked()
        }
    }
}
